package com.zyfdroid.bigdialerkit.utils;

import android.app.Activity;
import android.content.Intent;
import android.net.Uri;
import android.widget.TextView;
import android.widget.Toast;
import com.zyfdroid.bigdialerkit.R;

public class BaseActivity extends Activity {

    public void callPhone(String phoneNumber) {
        Intent i = new Intent(Intent.ACTION_CALL);
        i.setData(Uri.parse("tel:"+phoneNumber));
        startActivity(i);
    }

    public void showToast(String text){
        TextView tv = (TextView) getLayoutInflater().inflate(R.layout.toast_frame,null,false);
        tv.setText(text);
        Toast t = Toast.makeText(this, text, Toast.LENGTH_SHORT);
        t.setView(tv);
        t.show();
    }


}
